
<%@page contentType="text/html" pageEncoding="UTF-8" import= "com.model.Guess,java.util.List"%>

<div id="container">
    
<jsp:include page = "header.jsp" />

<div id ="content">

    <h1>Politics Guess's </h1>

       <% List<Guess> politicsList = (List<Guess>) request.getAttribute("politicsList");

        String message = "No Politics Guess's have been created";
        if (politicsList.isEmpty()) {%>

        <font style="color:red">

            <p><%=message%></p>

        </font>

        <%}


        for (Guess guess : politicsList) {

        %>



        <table align="center" class="table_format"  cellpadding="15" cellspacing="15">

            <tr>
                <th>Guess Category</th>
                <td><%=guess.getGuessCategory()%></td>
            </tr>

            <tr>
                <th>Guess</th>
                <td><%=guess.getGuessContent()%></td>
            </tr>

            <tr>
                <th>Guess Created By</th>
                <td><%=guess.getGuessCreatedBy()%></td>

            </tr>

            <tr>
                <th>Guess Created Date</th>

                <td><%=guess.getCurrentDateTime()%></td>
            </tr>

            <tr>
                <th>Guess Expires On</th>
                <td><%=guess.getGuessExpiryDate()%></td>

            </tr>



        </table><br><br>



        <%
        }



        %>

    </div>



<jsp:include page= "footer.jsp" />

</div>